package com.it.Demo1;

public class Point {
    public int x;
    public int y;

    public Point() {
    }

    public Point(int x, int y) {
        this.x = x;
        this.y = y;
    }
    public void movePoint(int dx, int dy){
        System.out.println("x坐标为："+x+"y坐标为："+y);
        System.out.println("移动后的x坐标为："+dx+"移动后的y坐标为："+dy);
    }

    public static void main(String[] args) {
        Point point1 = new Point();
        point1.movePoint(5,6);
        System.out.println("----------------");
        Point point2 = new Point(3, 4);
        point2.movePoint(10,12);
    }
}
